//
//  AppDelegate.h
//  JTY_App
//
//  Created by jty on 2025/3/29.
//

#import <UIKit/UIKit.h>
#import <Contacts/Contacts.h>

@interface AppDelegate : UIResponder <UIApplicationDelegate>

@property (strong, nonatomic) UIWindow *window;


typedef void (^ContactsCompletionBlock)(NSArray<CNContact *> *contacts);
typedef void (^ContactsFailureBlock)(NSError *error);

@property (nonatomic, copy) ContactsCompletionBlock contactsCompletionBlock;
@property (nonatomic, copy) ContactsFailureBlock failureBlock;

- (void)fetchContactsAsyncWithCompletion:(ContactsCompletionBlock)completion failure:(ContactsFailureBlock)failure;

@end

